home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 12770 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  852 b 

  1. Path: news.asiaonline.net!usenet
  2. From: Eddy Lau <eddylau@asiaonline.net>
  3. Newsgroups: comp.lang.c++
  4. Subject: Borland C++ 4.5 --> pascal calling convention
  5. Date: Fri, 22 Mar 1996 00:20:48 +0800
  6. Organization: Asia On-Line Limited, Wanchai, Hong Kong.
  7. Message-ID: <315181E0.594@asiaonline.net>
  8. NNTP-Posting-Host: 202.85.14.86
  9. Mime-Version: 1.0
  10. Content-Type: text/plain; charset=us-ascii
  11. Content-Transfer-Encoding: 7bit
  12. X-Mailer: Mozilla 2.0 (Win95; I)
  13.  
  14. I'm writing a DLL which is to be used in VB4 Pro 16-bit environment. 
  15. During my test in the VB, an error "Bad Calling convention" is occurred. 
  16. In my C++ code, I define the function as follows:
  17.  
  18.    double far pascal Test();
  19.  
  20. It seems that the C++ doesn't generate the code in pascal calling 
  21. convention (I'd tried the same DLL in VB4 Pro 32-bit and it work 
  22. properly). 
  23.  
  24. Pls help!!!
  25.  
  26. Thanks and Regards
  27.